﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.Text;
using System.Windows.Media.Media3D;


namespace GameBoard
{
    [DataContract]
    public class ModelVisualFactory : CharacterVisualFactory
    {
        public ModelVisualFactory(BaseVisualData theData) : base(theData)
        {

        }

        public override ModelVisual3D MakeVisual()
        {
            ModelVisual q = new ModelVisual();
            q.PopulateVisualData(VisualData);
            return q.VisualElement;
        }

        public override void SetLocation(Point3D newLocation)
        {
            var data = VisualData as ModelVisualData;
            data.Origin = newLocation;
        }
    }
}
